import request from "@/utils/request";

// 分页职位查询
export function listPagePosts(data) {
  return request({
    url: "/post/pages",
    method: "get",
    params: data,
  });
}

// 职位列表查询
export function listPosts(data) {
  return request({
    url: "/post/list",
    method: "get",
    params: data,
  });
}

// 新增职位
export function insertPost(data) {
  return request({
    url: "/post",
    method: "post",
    data,
  });
}

// 编辑职位
export function updatePost(data) {
  return request({
    url: "/post",
    method: "put",
    data,
  });
}

// 批量删除职位
export function deletePosts(data) {
  return request({
    url: "/post",
    method: "delete",
    params: data,
  });
}

// 删除职位
export function deletePost(data) {
  return request({
    url: "/post/" + data,
    method: "delete",
  });
}
